import request from '/@/api/request'

/** 查询机构列表 */
export const requestCompanyList = (data: CompanyListTypes.IRequest) => {
  return request.post<IPaginationResponse<CompanyListTypes.IResponse[]>>('/business/company/companyList', data)
}
/** 添加机构 */
export const requestSaveCompany = (data: SaveCompanyTypes.IRequest) => {
  return request.post<IBaseResponse<SaveCompanyTypes.IResponse>>('/business/company/saveCompany', data)
}
/** 编辑机构 */
export const requestUpdateCompany = (data: SaveCompanyTypes.IRequest) => {
  return request.post<IBaseResponse<SaveCompanyTypes.IResponse>>('/business/company/updateCompany', data)
}
/** 根据机构ID获取机构信息 */
export const requestGetCompanyById = (data: GetCompanyByIdTypes.IRequest) => {
  return request.get<IBaseResponse<GetCompanyByIdTypes.IResponse>>('/business/company/getCompanyById', data)
}
